package top.cardone.data.service.impl;

import org.springframework.data.domain.Page;
import org.springframework.transaction.annotation.Transactional;
import top.cardone.data.dao.PageDao;
import top.cardone.data.service.PageService;

import java.util.Map;

/**
 * Created by yao hai tao on 2015/8/24.
 */
@Transactional(readOnly = true)
public class PageServiceImpl<Dao extends PageDao> extends SimpleServiceImpl<Dao> implements PageService {
    @Override
    public Page<Map<String, Object>> page(Object page) {
        return this.dao.page(page);
    }

    @Override
    public <P> Page<P> page(Class<P> mappedClass, Object page) {
        return this.dao.page(mappedClass, page);
    }
}
